package com.bodu.depress.mapper;

import com.bodu.core.common.CommonMapper;
import com.bodu.depress.entity.request.DepressCollectDetailRequest;
import com.bodu.depress.entity.vo.DepressCollectDetailVo;
import com.bodu.depress.entity.vo.DepressQuestionVo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 题集明细 Mapper
 *
 * @author Administrator
 */
@Mapper
public interface DepressCollectDetailMapper extends CommonMapper<DepressCollectDetailRequest, DepressCollectDetailVo> {

    /**
     * 查询编号
     * @param collectId 集合名称
     * @return
     */
    List<Long> getQuestionIdsByCollectId(@Param("collectId") Long collectId);

    /**
     * 根据CollectId 删除数据
     * @param collectId
     * @return
     */
    Integer updateDelFlagByCollectId(@Param("collectId") Long collectId);

    Integer batchSave(@Param("collectId") Long collectId, @Param("selectQuestionId") List<Long> selectQuestionId);

    /**
     * 得到题目集合
     * @param collectId
     * @return
     */
    List<DepressQuestionVo> findDepressQuestions(@Param("collectId") Long collectId);

}
